Serial ATA (Advanced Technology Attachment) is an evolutionary replacement for the Parallel ATA physical storage interface. Serial ATA (SATA) is a computer bus primarily designed for transfer of data between a computer processor and hard disk and has at least three advantages over Parallel ATA, namely speed, cable management, and Serial ATA's ability of being hot swappable.
There are three interface power states supported in Serial ATA: PhyReady, Partial and Slumber. In PhyReady (or power up) state, the PHY (physical) logic and main PLL (phase-locked loop) are both on and active, and the interface is synchronized and capable of receiving and sending data. Partial and Slumber are two power saving (or power down) modes. In both Partial and Slumber states, the PHY logic is powered, but is in a reduced power state. However, while the exit latency from Partial state is generally no longer than 10 μs (microseconds), the exit latency from Slumber state is generally no longer than 10 ms (milliseconds).
When a Serial ATA interface is idle (i.e., when either a Serial ATA host controller or a Serial ATA device is not active) for a period of time, it is desirable to put the interface into a power saving mode. In addition to saving power while in a power saving mode, the interface lifetime may be increased.
With the adoption of the Serial Attached SCSI (SAS) protocol, it is possible to create a SAS/SATA host controller, to which a SATA device (e.g., a SATA drive or the like) may be either directly attached or accessed through a SAS Expander via the SCSI Tunneling Protocol (STP). In other words, a SAS/SATA host controller supports both SAS and SATA, and a SATA device may be either directly attached to the SAS/SATA controller or may be attached to a SAS expander that is attached to the SAS/SATA controller. In the case where the SATA device is attached via the expander, the host controller uses the SAS STP protocol to access the device. In this case, no SATA power management is allowed per the SAS specification. On the other hand, in the case where the SATA device is directly attached to the host controller, SATA power management is allowed.
Thus, it would be desirable to provide a method and apparatus of automatic power management control for a Serial ATA device directly attached to a SAS/SATA host controller.